import java.util.Scanner;

/**
 * @author: gao
 * @create-date: 2025/5/31 19:18
 */

public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        while (true) {
            String ID = in.nextLine();
            if (ID.length() != 18 || !ID.matches("\\d{18}")) {
                System.out.println("Invalid data, input again!");
                continue;
            }
            String year = ID.substring(6,10);
            String month = ID.substring(10,12);
            System.out.println(year + "," + month);
            break;
        }
    }
}